package com.yuan.springcloud.user.bean.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.Version;
import com.yuan.springcloud.common.db.bean.Entity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @author YouYuan
 * @date 2020/8/15 21:27
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "用户实体类")
@Data
@TableName("user")
public class UserPO extends Entity {

    @ApiModelProperty(value = "用户ID", example = "1")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "用户名", example = "YouYuan")
    private String username;

    @ApiModelProperty(value = "密码")
    private String password;

    @ApiModelProperty(value = "盐值", example = "120")
    private Integer salt;

    @ApiModelProperty(value = "昵称", example = "友缘")
    private String nickname;

    @ApiModelProperty(value = "邮箱", example = "xiyousuiyuan@163.com")
    private String email;

    @ApiModelProperty(value = "手机号")
    private String mobile;

    @ApiModelProperty(value = "用户类型")
    private Integer userType;

    @ApiModelProperty(value = "启用状态(0:启用,1:禁用)")
    private Integer isEnable;

    @ApiModelProperty(value = "删除状态(0:未删除,1:已删除)")
    private Integer isDelete;

    @ApiModelProperty(value = "版本号")
    @Version
    private Integer version;

}
